Hill Cipher implementation python